package com.hhu.softpractise.service;

import com.hhu.softpractise.model.entiy.PostThumb;
import com.baomidou.mybatisplus.extension.service.IService;
import com.hhu.softpractise.model.entiy.User;

/**
* @author 35534
* @description 针对表【post_thumb(帖子点赞)】的数据库操作Service
* @createDate 2025-06-23 14:16:35
*/
public interface PostThumbService extends IService<PostThumb> {

    /**
     * 点赞
     *
     * @param postId
     * @param loginUser
     * @return
     */
    int doPostThumb(long postId, User loginUser);

    /**
     * 帖子点赞（内部服务,事务）
     *
     * @param userId
     * @param postId
     * @return
     */
    int doPostThumbInner(long userId, long postId);
}
